﻿using OpenTelemetry.Metrics;
using System.Runtime.CompilerServices;

namespace BasicModuleOrm.ProductRespository
{
    public static  class ProductRepositoryServiceCollectionExtensions
    {
        public static IServiceCollection AddProductReposotory(this IServiceCollection serviceDescriptors, Action<ProductReposotoryOptions> action) 
        {
            ProductReposotoryOptions productReposotoryOptions = new ProductReposotoryOptions();
            productReposotoryOptions.Services = serviceDescriptors;
            action.Invoke(productReposotoryOptions);
            return serviceDescriptors;
        }
    }
}
